package com.spring.demo01;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

/**
 * Hello world!
 *
 */
public class App 
{
    public static void main( String[] args )
    {
        System.out.println( "Hello World!" );
        ApplicationContext context = new ClassPathXmlApplicationContext("spring.xml");
//        ApplicationContext context = new ClassPathXmlApplicationContext("spring.xml", "daos.xml");
        MyService myservice = (MyService) context.getBean("myservice");
        String item = myservice.getItem();
        System.out.println(item);
    }
}
